Skip to content

Fixes to EuiSearchBar etc types#3147

Merged
bevacqua merged 4 commits intoelastic:masterfrom
pugnascotia:3138-search-bar-fixes
Mar 26, 2020
Merged

Fixes to EuiSearchBar etc types#3147
bevacqua merged 4 commits intoelastic:masterfrom
pugnascotia:3138-search-bar-fixes

Conversation

@pugnascotia
Copy link
Contributor

Closes #3138.

  • Rename FilterConfig to SearchFilterConfig and export it via EuiSearchBar.
  • Export FieldValueOptionType via EuiSearchBar.
  • Change EuiSearchBoxProps to extend EuiFieldSearchProps, so that it includes all the HTML properties such as disabled. Also rework the related component code to forward on more props via ...rest.

@pugnascotia
Copy link
Contributor Author

@bevacqua I think this PR address most of the points you raised in #3138. The only one left is the autoClose point. This is supported by the <FieldValueSelectionFilter> component, but it isn't available for use via <EuiSearchBar> (for boring code reasons).

@chandlerprall we could address this by moving autoClose into the FieldValueSelectionFilterConfigType type - what do you think? It would mean fiddling about default props and such.

@kibanamachine
Copy link

Preview documentation changes for this PR: https://eui.elastic.co/pr_3147/

Copy link
Contributor

@chandlerprall chandlerprall left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we could address this by moving autoClose into the FieldValueSelectionFilterConfigType type - what do you think? It would mean fiddling about default props and such.

I don't see how autoClose could ever have been used in its current form. We don't export FieldValueSelectionFilter in a consumable way, so I believe autoClose can be moved to the config object with no problems.

@kibanamachine
Copy link

Preview documentation changes for this PR: https://eui.elastic.co/pr_3147/

Copy link
Contributor

@chandlerprall chandlerprall left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changes LGTM! Thanks @pugnascotia

@bevacqua bevacqua merged commit dd8af25 into elastic:master Mar 26, 2020
@bevacqua
Copy link
Contributor

Thanks folks!

@kibanamachine
Copy link

Preview documentation changes for this PR: https://eui.elastic.co/pr_3147/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Some EuiSearchBar TypeScript issues

4 participants